<template>
    <div>
        获取商品详情页
        {{$route.params.id}}
    </div>
</template>

<script>
export default {
    name: 'VueanliDetail',

    data() {
        return {
            arr:[]
        };
    },

    mounted() {
        //发起请求
        // axios.get(/xxx/${this.$route.params.id}`).then(res=>{
            
        // })
        axios.get(`/detail/${this.$route.params.id}`).then(res=>{
            this.arr = res.data.list
        })
    },

    methods: {
        
    },
};
</script>

<style lang="scss" scoped>

</style>